package vashion.azeroth.core.service.impl.item;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import vashion.azeroth.core.item.pojo.ItemDO;
import vashion.azeroth.core.item.query.ItemQueryDO;
import vashion.azeroth.core.manager.item.ItemReadManger;
import vashion.azeroth.core.result.ApiResult;
import vashion.azeroth.core.service.item.ItemReadService;

import java.util.List;

/**
 * Created by tingting on 15/8/31.
 */
@Service
public class ItemReadServiceImpl implements ItemReadService {

    @Autowired
    private ItemReadManger itemReadManger;

    public ApiResult<ItemDO> getItemDetail(long itemId, boolean needSku) {
        return itemReadManger.getItemDetail(itemId, needSku);
    }

    public ApiResult<List<ItemDO>> queryItem(ItemQueryDO itemQueryDO) {

        return itemReadManger.queryItem(itemQueryDO);
    }

}
